﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using NUnit.Framework;
using WatiN.Core;
using WatiN.Core.Native;

[ElementTag("input", InputType = "text", Index = 0)]
[ElementTag("input", InputType = "password", Index = 1)]
[ElementTag("input", InputType = "textarea", Index = 2)]
[ElementTag("input", InputType = "hidden", Index = 3)]
[ElementTag("textarea", Index = 4)]
[ElementTag("input", InputType = "email", Index = 5)]
[ElementTag("input", InputType = "url", Index = 6)]
[ElementTag("input", InputType = "number", Index = 7)]
[ElementTag("input", InputType = "range", Index = 8)]
[ElementTag("input", InputType = "search", Index = 9)]
[ElementTag("input", InputType = "color", Index = 10)]
public class TextFieldExtended : TextField
{
    public TextFieldExtended(DomContainer domContainer, INativeElement element)
        : base(domContainer, element)
    {
    }

    public TextFieldExtended(DomContainer domContainer, ElementFinder finder)
        : base(domContainer, finder)
    {
    }

    public static void Register()
    {
        Type typeToRegister = typeof(TextFieldExtended);
        ElementFactory.RegisterElementType(typeToRegister);
    }
}

[ElementTag("input", InputType = "checkbox", Index = 0)]
public class CheckBoxExtended : CheckBox
{
    public CheckBoxExtended(DomContainer domContainer, INativeElement element)
        : base(domContainer, element)
    {
    }

    public CheckBoxExtended(DomContainer domContainer, ElementFinder finder)
        : base(domContainer, finder)
    {
    }

    public static void Register()
    {
        Type typeToRegister = typeof(ButtonExtended);
        ElementFactory.RegisterElementType(typeToRegister);
    }
}

[ElementTag("input", InputType = "submit", Index = 0)]
public class ButtonExtended : Button
{
    public ButtonExtended(DomContainer domContainer, INativeElement element)
        : base(domContainer, element)
    {
    }

    public ButtonExtended(DomContainer domContainer, ElementFinder finder)
        : base(domContainer, finder)
    {
    }

    public static void Register()
    {
        Type typeToRegister = typeof(ButtonExtended);
        ElementFactory.RegisterElementType(typeToRegister);
    }
}